The present invention relates to a technique for efficiently acquiring such logs as communication logs and alarm logs in transmission systems.
As conventional techniques for writing communication logs, there are methods of writing data to be logged with fixed lengths and writing data to be logged with variable lengths.
FIG. 1 shows the former method of writing logs as fixed-length data.
In the system shown in FIG. 1, such variable-length data as communication data transmitted between processors and/or data indicative of alarm occurrences caused by errors in communication are written with a fixed length. For writing those data, a log area pointer is used to specify an address at which log information should be written next time, as shown in FIG. 1. When information to be logged is generated due to communication and others, the information is written into an address in a log area specified by the log area pointer. Although such unfixed data as the foregoing communication data and/or alarm data are written in a log area as logged information, fixed-length areas are secured in the log area. The log area pointer is made to go forward by a quantity corresponding to a fixed-length area, thus specifying the next address at which data is to be written next time.
In such log writing way, if the log files are desired to be traced backward into the past, tracing the pointer on a condition that an address corresponding to a known fixed-length area is reduced each time easily can show how log data are written in the past.
In contrast, the way shown in FIG. 2 is used to write such variable-length data as communication data or data showing alarm occurrence as log files by storing those variable-length data into each variable-length log area. As shown in FIG. 2, a log area pointer designates the next address at which log information will be written. In the case that information to be logged arises due to performing communication and others, the information is written at an address in the log area currently specified by the log area pointer. The information to be logged in a log area is made up of a data length and data, and the data length indicates a quantity of log data written. The log area pointer is made to go forward by an amount of "data amount +2", so that it indicates the next data-writing position.
Another conventional technique similar to the above is disclosed by a Japanese Patent Laid-open (KOKAI) publication No. 6-314220 as a method of searching update start points of data storage files. Specifically, every access to data storage files with fixed-length records, the logging date and time and the file size of a final record is preserved in a different file. For data storage files of variable-length records, the logging date and time, record length, and file size of a final record are preserved in a different file.
For performing accumulation processing for data storage files, it takes time to accumulate from its top file. Thus, in order to restrict the processing to a new range produced after the last accumulation processing, data updated (update start point) after the last accumulation processing are searched using the logging date, record length (only for variable-length records), and file size of the final record which have been preserved in the different file.
Another conventional technique for log information collection method is disclosed by a Japanese Patent Laid-open (KOKAI) publication No. 6-6421. This shows a writing technique for securing data buffer areas and log areas within a memory of a channel system with the object of increasing efficiency in memory use as well as facilitating its management. In order to accomplish those objects, the Japanese Patent Laid-open (KOKAI) publication No. 6-6421 uses pointers A and B which indicate respectively the upper and lower ends of a log area and pointers C and D which indicates respectively the top and bottom ends of log data with a given length. If an empty area is made between the pointers A and C or between the pointers B and D, a data buffer area is secured within the empty area, and the log area is updated by moving the pointers A and B to the upper and lower ends of a remaining area made by excluding the secured data buffer area from the log area. In contrast, if an empty area does not yield between the pointers A and C or between the pointers B and D, a data buffer is prohibited from being secured. Repeating the same procedure as the above, the log areas and the data buffer area are secured for data to be logged inputted in sequence. In this disclosed technique, an alternative approach is that, by moving the pointers A and B to the upper and lower ends of an area including a data buffer area, the data buffer area is taken into the log area.
The way shown in FIG. 1 requires all the logs to be equal in log length. Therefore, in logging variable-length data such as communication data, if the data are less than in length a fixed-length area, areas in which no data are written are produced, preventing an efficient use of a logging area.
In particular, in transmission systems, it is carried out that alarms are read from their hardware units every 1sec., as a typical value. Thus logging alarm information as-read from the hardware units requires a huge amount of logging area. One countermeasure to avoid this problem is to perform degeneracy processing with alarm information, and to write the processed data. However, owing to the fact that the degeneracy processing collects a plurality of pieces of alarm information into one piece of alarm information, it is impossible to obtain the as-read alarm information from the hardware units from the logs formed by data which experienced the degeneracy processing. It is often not to obtain necessary information in such cases as tracing failures.
In the way shown in FIG. 2, the log area pointer sustains only an address at which the next writing is done and areas wherein log data are written are variable-lengths. Hence, if trying to trace the log data to the past to read them in sequence in the ascent order, it is impossible to obtain information showing at where a certain log to be traced starts, resulting in failures in reading.
Therefore, both of the logging with a fixed length and the logging with variable lengths have advantages and disadvantages.
Additionally, the foregoing publication No. 6-314220 provides only an update start position at or after the last access. Moreover this publication technique absolutely requires the logging date and time of the final record and the file sizes. Further, according to this publication, there is a possibility that the top of the data files stored may be deleted due to the limitation in the file size. Accordingly, the date and the record length of the final record at the last update are required (only in the case of variable-length records).
The foregoing other publication No. 6-6421 discloses a technique by which a memory incorporated in a channel apparatus can be used with no unused area left. But this technique focuses on only an arrangement of areas for log files and buffers into the same area in a suitable way.
Accordingly, it is an object of the present invention to provide a logging system capable of efficiently using logging areas with no empty spacing left and efficiently tracing back the logs to the past.